package org.example.enums;

/**
 * 
 * @Title: RepaymentTypeTypeEnum 
 * @Description: 金融产品管理-->还款方式
 * @author ws
 * @date 2018年5月15日 下午5:22:40
 */

public enum RepaymentTypeEnum {

	SHIER("按月还款",1),
	ERSHISI("按季还款",2),
	WUXIANQI("按租约周期支付",3);
	
	private String name;
	private int index;
	
	private RepaymentTypeEnum(String name, int index) {
		this.name = name;
		this.index = index;
	}
	public static String getName(int index){
		for (RepaymentTypeEnum c : RepaymentTypeEnum.values()) {
			if(c.getIndex() == index){
				return c.name;
			}
		}
		return null;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public int getIndex() {
		return index;
	}
	public void setIndex(int index) {
		this.index = index;
	}
	
}
